<!DOCTYPE html>
<!--[if IE 7 ]>   <html lang="en" class="ie7 lte8"> <![endif]--> 
<!--[if IE 8 ]>   <html lang="en" class="ie8 lte8"> <![endif]--> 
<!--[if IE 9 ]>   <html lang="en" class="ie9"> <![endif]--> 
<!--[if gt IE 9]> <html lang="en"> <![endif]-->
<!--[if !IE]><!--> <html lang="en"> <!--<![endif]-->
<head>
<meta charset="utf-8">
<!--[if lte IE 9 ]><meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"><![endif]-->

<!-- iPad Settings -->
<meta name="apple-mobile-web-app-capable" content="yes" />
<meta name="apple-mobile-web-app-status-bar-style" content="black-translucent" /> 
<meta name="viewport" content="user-scalable=no, initial-scale=1.0, width=device-width">
<!-- iPad End -->

<title>Admin CMS</title>

<link rel="shortcut icon" href="<?php echo STATIC_DOMAIN ?>favicon.ico">

<!-- STYLESHEETS -->

<?php echo $combinedCss ?>
<style type = "text/css">
    #loading-container {position: absolute; top:50%; left:50%;}
    #loading-content {width:800px; text-align:center; margin-left: -400px; height:50px; margin-top:-25px; line-height: 50px;}
    #loading-content {font-family: "Helvetica", "Arial", sans-serif; font-size: 18px; color: black; text-shadow: 0px 1px 0px white; }
    #loading-graphic {margin-right: 0.2em; margin-bottom:-2px;}
    #loading {background-color: #eeeeee; height:100%; width:100%; overflow:hidden; position: absolute; left: 0; top: 0; z-index: 99999;}
</style>

<!-- STYLESHEETS END -->

<!--[if lt IE 9]>
<script src="<?php echo STATIC_DOMAIN ?>js/admin/html5.js"></script>
<script type="text/javascript" src="<?php echo STATIC_DOMAIN ?>js/admin/selectivizr.js"></script>
<![endif]-->

</head>
<body class="login" style="overflow: hidden;">
    <div id="loading"> 

        <script type = "text/javascript"> 
            var base_url = '<?php echo STATIC_DOMAIN ?>';
            document.write("<div id='loading-container'><p id='loading-content'>" +
                           "<img id='loading-graphic' width='16' height='16' src='"+base_url+"images/admin/ajax-loader-eeeeee.gif' /> " +
                           "Loading...</p></div>");
        </script> 

    </div> 

    <div class="login-box">
    	<section class="portlet login-box-top">
            <header>
                <h2 class="ac">Admin CMS</h2>
            </header>
            <section>
                <?php if(form_error() != '' || $error != ''): ?>
                    <ul class="message error">
                        <?php echo form_error(); ?>
                        <?php if($error != ''): ?>
                            <li><?php echo $error ?></li>
                        <?php endif; ?>
                    </ul>
                <?php endif; ?>
                <form id="form" class="has-validation" action="" method="POST" style="margin-top: 30px">
                    <p style="margin-bottom: 30px">
                        <input type="text" id="username" class="full" value="" name="username" required="required" placeholder="Tài khoản" />
                    </p>
                    <p style="margin-bottom: 30px">
                        <input type="password" id="password" class="full" value="" name="password" required="required" placeholder="Mật khẩu" />
                    </p>
                    <p class="clearfix">
<!--                        <span class="fl" style="line-height: 23px;">
                            <label class="choice" for="remember">
                                <input type="checkbox" id="remember" class="" value="1" name="remember"/>
                                Ghi nhớ tài khoản này
                            </label>
                        </span>-->

                        <button class="fr" type="submit">Đăng nhập</button>
                    </p>
                </form>
<!--                <footer class="ac">
                    <a href="#" class="button">Reset Password</a>
                    <a href="#" class="button">Register</a>
                </footer>-->
            </section>
    	</section>
	</div>
    
    <!-- MAIN JAVASCRIPTS -->
    <?php echo $combinedJs; ?>
    <!-- MAIN JAVASCRIPTS END -->

    <!-- LOADING SCRIPT -->
    <script>
    $(window).load(function(){
        $("#loading").fadeOut(function(){
            $(this).remove();
            $('body').removeAttr('style');
        });
    });
    $(document).ready(function(){
        $("#form").validator({ 
            lang : 'vi',
            position: 'bottom left', 
            messageClass:'form-error',
            message: '<div><em/></div>' // em element is the arrow
        });
        $.tools.validator.localize('vi', {
            '[required]' : 'Trường này không được để trống'
        });
    });
    </script>
    <!-- LOADING SCRIPT -->

</body>
</html>
